package com.kx.center.service;

import java.util.HashMap;
import java.util.List;

import javax.servlet.http.HttpServletRequest;

import com.kx.center.entity.Account;
import com.kx.center.entity.Food;
import com.kx.center.entity.FoodCategory;
import com.kx.center.entity.FoodType;
import com.kx.center.entity.query.QueryFoodCategory;
import com.kx.center.entity.query.QueryResult;

public interface FoodService {
	//食品分类
	public boolean insertFoodCategory(FoodCategory foodCategory);
	public QueryResult queryFoodCategory(QueryFoodCategory queryFoodCategory);
	public void updateFoodCategoryById(FoodCategory foodCategory);
	public void deleteFoodCategoryById(Account account, Integer id);
	public FoodCategory findFoodCategoryByName(String name, Integer companyId);
	public String findAllFood(Integer companyId);
	//食品
	public boolean insertFood(HttpServletRequest request,Food food);
	public QueryResult queryFood(QueryFoodCategory queryFoodCategory);
	public List<Food> findFoodByCategoryId(Integer id);
	public List<Food> findFoodByUnitId(Integer id);
	public void updateFoodById(Account account, HashMap<String, Object> map);
	public void deleteFoodById(Account account, Integer id);
	public Food findFoodBySku(String sku, Integer companyId);
	public Food findFoodById(Integer id);
	//食品规格
	public boolean insertFoodType(FoodType foodType);
	public QueryResult queryFoodType(QueryFoodCategory queryFoodCategory);
	public FoodType findFoodTypeByName(String name, Integer companyId);
	public void updateFoodTypeById(FoodType foodType);
	public void deleteFoodTypeById(Account account, Integer id);
}
